package cn.xing.managementSystem.repository;

import cn.xing.managementSystem.domain.Course;
import cn.xing.managementSystem.enums.CourseType;
import cn.xing.managementSystem.repository.base.BaseEntityRepository;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;

import java.util.List;

/**
 * @author cuixing
 * @package cn.xing.managementSystem.repository
 * @class CourseRepository
 * @email xing.cui@magicwindow.cn
 * @date 2018/4/24 上午10:48
 * @description
 */
public interface CourseRepository extends BaseEntityRepository<Course> {

    Course findByIdAndAndDeletedIsFalse(Long id);

    Page<Course> findByDeletedIsFalse(Pageable pageable);

    List<Course> findByCourseTypeAndDeletedIsFalse(CourseType courseType);
}